package com.gable.exhibition.service;

import com.gable.common.util.ReturnResultUtil;
import com.gable.exhibition.model.Appoint;
import com.gable.exhibition.model.Maintainer;
import com.gable.exhibition.model.Upkeep;
import com.gable.exhibition.model.User;
import com.gable.exhibition.view.EventView;
import com.gable.exhibition.view.UpkeepView;

import java.util.Map;

/**
 * Created by Lesson on 2018/2/25.
 */
public interface UpkeepService {

    /**
     * 获取保养列表
     * @param upkeepView
     * @Create user jacky
     * @Create date 2018/2/25
     * @return
     */
    ReturnResultUtil queryUpkeepList(UpkeepView upkeepView);


    /**
     * 添加一条保养记录
     * @param upkeepView
     * @Create user jacky
     * @Create date 2018/2/25
     * @return
     */
    ReturnResultUtil addUpkeep(UpkeepView upkeepView,Integer hospital_user);

    /**
     * 根据保养id获取保养详情
     * @param upkeepId
     * @Create user jacky
     * @Create date 2018/2/25
     * @return
     */
    ReturnResultUtil queryUpkeepInfo(UpkeepView upkeepView);

    /**
     * 根据保养id获取要分配的服务商信息
     * @param upkeepId
     * @Create user jacky
     * @Create date 2018/2/28
     * @return
     */
    ReturnResultUtil assignServiceInit(Long upkeepId);

    /**
     * 根据维修商id和工程师姓名，带出电话号码
     * @param maintainerId
     * @param engineerName
     * @Create user jacky
     * @Create date 2018/3/1
     * @return
     */
    ReturnResultUtil queryEngineerPhoneByName(Long maintainerId,String engineerName);

    /**
     * 保存平台分配维修商信息
     * @param upkeep
     * @Create date 2018/3/1
     * @Create user jacky
     * @return
     */
    ReturnResultUtil saveAssign(UpkeepView upkeep,User user);

    /**
     * 确认保养信息
     * @param upkeep
     * @Create date 2018/3/1
     * @Create user jacky
     * @return
     */
    ReturnResultUtil saveComple(UpkeepView upkeep,User user);

    /**
     * 保养信息补全
     * @param upkeepView
     * @Create date 2018/3/1
     * @Create user jacky
     * @return
     */
    ReturnResultUtil saveUpkeepData(UpkeepView upkeepView,User user);

    /**
     * 查询当前设备是否在保养中
     * @param deviceId
     * @Create user jacky
     * @Create date 2018/3/21
     * @return
     */
    ReturnResultUtil queryDeviceIsUpkeep(Long deviceId);


    /**
     * 审核维修商信息，并返回最新的保养记录
     * @param maintainer
     * @Create user jacky
     * @Create date 2018/3/23
     * @return
     */
    ReturnResultUtil saveExamineMaintainer(Maintainer maintainer,Upkeep upkeep);

    /**
     * 保养多指派公司或者指派工程师
     * @param appoint
     * @Create user jacky
     * @Create date 2018/3/27
     * @return
     */
    ReturnResultUtil assignServiceOrEngineer(Appoint appoint);

    /**
     * 修改指派的工程师信息
     * @param appoint
     * @Create user jacky
     * @Create date 2018/3/27
     * @return
     */
    ReturnResultUtil updateEngineerNameAndEngineerPhone(Appoint appoint,User user);

    /**
     * 工程师填写预计上门时间
     * @param upkeep
     * @Create user jacky
     * @Create date 2018/3/27
     * @return
     */
    ReturnResultUtil dxpectedToDoorByEngineer(Upkeep upkeep);

    /**
     * 保养提醒
     * @param map
     * @Create user jacky
     * @Create date 2018/3/28
     * @return
     */
    ReturnResultUtil remindUpkeepList(Map map);

    /**
     * 根据工程师姓名加载电话号码
     * @param map
     * @Create user jacky
     * @Create date 2018/4/9
     * @return
     */
    ReturnResultUtil queryPhoneByHospital(Map map);
}
